package manager;

import entities.Department;
import entities.EmployeeDepartmentHistory;
import entities.Holiday;
import entities.Shift;
import entities.ShiftRequest;
import entities.User;
import entities.ViewScheduler;
import entities.ViewShiftRequest;
import java.util.ArrayList;
import java.util.Date;

public class ManagerDriver {

    private DataManager dataManager;

    public ManagerDriver(DataManager dataManager) {
        this.dataManager = dataManager;
    }
    
    public ArrayList<User> showEmployee() {
        return dataManager.showEmployee();
    }
    
    public User showEmployeeByID(int id) {
        return dataManager.showEmployeeByID(id);
    }
    
    public boolean insertEmployee(User employee) {
        return dataManager.insertUser(employee);
    }
    
    public boolean updateEmployee(User employee) {
        return dataManager.updateUser(employee);
    }
    
    public boolean deleteEmployee(User employee) {
        return dataManager.deleteUser(employee);
    }
    
    public ArrayList<ViewScheduler> showViewScheduler() {
        return dataManager.showViewHeadScheduler();
    }
    
    public ViewScheduler showViewSchedulerByPK(int eid, int did, int sid, Date date) {
        return dataManager.showViewSchedulerByPK(eid, did, sid, date);
    }
    
    public boolean insertEmployeeDepH(EmployeeDepartmentHistory record) {
        return dataManager.insertEmployeeDepH(record);
    }
    
    public boolean updateEmployeeDepH(EmployeeDepartmentHistory record) {
        return dataManager.updateEmployeeDepH(record);
    }
    
    public boolean deleteEmployeeDepH(EmployeeDepartmentHistory record) {
        return dataManager.deleteEmployeeDepH(record);
    }
    
    public ArrayList<ViewShiftRequest> showHeadsRequest() {
        return dataManager.showSRByRole(3);
    }
    
    public boolean insertShiftRequest(ShiftRequest request) {
        return dataManager.insertShiftRequest(request);
    }
    
    public boolean updateShiftRequest(ShiftRequest request) {
        return dataManager.updateShiftRequest(request);
    }
    
    public boolean deleteShiftRequest(ShiftRequest request) {
        return dataManager.deleteShiftRequest(request);
    }
    
    public boolean insertHoliday(Holiday holiday) {
        return dataManager.insertHoliday(holiday);
    }
    
    public boolean updateHoliday(Holiday holiday) {
        return dataManager.updateHoliday(holiday);
    }
    
    public boolean deleteHoliday(Holiday holiday) {
        return dataManager.deleteHoliday(holiday);
    }
    
    public boolean insertDepartment(Department dep) {
        return dataManager.insertDepartment(dep);
    }
    
    public boolean updateDepartment(Department dep) {
        return dataManager.updateDepartment(dep);
    }
    
    public boolean deleteDepartment(Department dep) {
        return dataManager.deleteDepartment(dep);
    }
    
    public boolean insertShift(Shift shift) {
        return dataManager.insertShift(shift);
    }
    
    public boolean updateShift(Shift shift) {
        return dataManager.updateShift(shift);
    }
    
    public boolean deleteShift(Shift shift) {
        return dataManager.deleteShift(shift);
    }
    
    public boolean setStatusOfSR(int requestID, int status) {
        return dataManager.setStatusOfSR(requestID, status);
    }
}
